Create Card Token
Cards
Create Card Token
Tokenize a credit card securely using Stripe
POST
Create Card Token
Documentation Index
Fetch the complete documentation index at: https://mintlify.com/peLuis123/Stripe_Back/llms.txt
Use this file to discover all available pages before exploring further.
Never store raw card data on your servers. This endpoint creates a secure token through Stripe that represents the card information.
Request Body
The card number, as a string without any separators.For testing, use Stripe test card:
4242424242424242The card’s expiration month (1-12).Example:
"12"The card’s expiration year as a 4-digit number.Example:
"2026"The card’s CVC/CVV security code.Example:
"123"Response
Indicates if the request was successful (
true) or failed (false).Human-readable message describing the result.Example:
"Tarjeta tokenizada correctamente"The tokenized card data.
Example Request
Example Response
Error Codes
| Code | Description |
|---|---|
incorrect_number | The card number is incorrect |
invalid_expiry_month | The expiration month is invalid |
invalid_expiry_year | The expiration year is invalid |
invalid_cvc | The CVC/CVV code is invalid |
card_declined | The card was declined by the issuer |
Test Cards: Use Stripe’s test card numbers for development:
- Success:
4242424242424242 - Declined:
4000000000000002 - Insufficient funds:
4000000000009995